using Microsoft.Pex.Framework;

namespace Benchmarks.Fitnex
{
    [PexClass(typeof(FitnexTest))]
    [SearchFrontierDepthFirstAttribute]
    public partial class FitnexTest
    {
        [PexMethod]
        public bool TestLoop(int x, int[] y)
        {
            if (x == 90)
            {
                for (int i = 0; i < y.Length; i++)
                {
                    if (y[i] == 15)
                    {
                        x++;
                    }
                }
                if (x == 110)
                {
                    return true;
                }
            }
            return false;
        }
    }

    [PexClass(typeof(FitnexTest2))]
    [RandomSearchFrontier(false)]
    public partial class FitnexTest2
    {
        [PexMethod]
        public bool TestLoop(int x, int[] y)
        {
            if (x == 90)
            {
                for (int i = 0; i < y.Length; i++)
                {
                    if (y[i] == 15)
                    {
                        x++;
                    }
                }
                if (x == 110)
                {
                    return true;
                }
            }
            return false;
        }
    }

    [PexClass(typeof(FitnexTest3))]
    [OnlyFitnexSearchFrontier(false)]
    public partial class FitnexTest3
    {
        [PexMethod]
        public bool TestLoop(int x, int[] y)
        {
            if (x == 90)
            {
                for (int i = 0; i < y.Length; i++)
                {
                    if (y[i] == 15)
                    {
                        x++;
                    }
                }
                if (x == 110)
                {
                    return true;
                }
            }
            return false;
        }
    }
}